#include<stdio.h>
#include<stdlib.h>
#include<conio.h>
int main()
{
    int x,y;
    int i=10;
    int j=5;
    char input;
    int isFired=0;
    int ny=5;
    int iskilled=0;

    while(1)
    {
        system("cls");
        if(iskilled==0)
        {
            for(x=0;x<i;x++)
                printf("\n");
            printf("+\n");
        }

        if(isFired==0)
        {
            for(x=0;x<i;x++)
                printf("\n");
            printf("+\n");
        }
        else
        {
            for(x=0;x<i;x++)
            {
                 for(y=0;y<j;y++)
                    printf(" ");
                printf("  |\n");
            }

        }
            if(y+2==ny)
                iskilled=1;


        for(y=0;y<j;y++)
            printf(" ");
        printf("  *\n");
        for(y=0;y<j;y++)
            printf(" ");
        printf("*****\n");
        for(y=0;y<j;y++)
            printf(" ");
        printf(" * *\n");

     //scanf("%c",&input);
    input=getch();
     if(input=='s');
        i++;
     if(input=='w');
        i--;
     if(input=='a');
        j--;
     if(input=='d');
        j++;
     if(isFired==' ');
        isFired=1;

    }

    return 0;
}

